package com.nisure.service.impl;

import java.util.Date;
import java.util.List;
import java.util.Map;

import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import com.nisure.dao.AccountDao;
import com.nisure.entity.AccountEntity;
import com.nisure.service.AccountService;

@Service
public class AccountServiceImpl implements AccountService{

	@Autowired
	private AccountDao accountDao;
	@Override
	public String getRefreshToken(long userId) {
		// TODO Auto-generated method stub
		return accountDao.getRefreshToken(userId);
	}
	@Override
	public int addAccount(Map<String,Object> map) {
		// TODO Auto-generated method stub
		return accountDao.addAccount(map);
	}
	@Override
	public int updateRefreshToken(Map<String, Object> map) {
		return accountDao.updateRefreshToken(map);
	}
	@Override
	public List<AccountEntity> queryAccount(Map<String, Object> map){
		return accountDao.queryAccount(map);
	}
	public int updateAccount(Map<String, Object> map){
		return accountDao.updateAccount(map);
	}
	@Override
	public List<AccountEntity> queryAccountByUserId(Map<String, Object> map) {
		
		return accountDao.queryAccountByUserId(map);
	}
	@Override
	public List<Long> queryAllUserId() {
		// TODO Auto-generated method stub
		return accountDao.queryAllUserId();
	}
	
}
